<!-- HTML header for doxygen 1.8.13-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.2"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>WiFi Host Driver Board Support Package Integration (whd-bsp-integration)</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen_style.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><a href="http://www.cypress.com/"><img alt="Logo" src="logo.png"/></a></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">WiFi Host Driver Board Support Package Integration (whd-bsp-integration)</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.2 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search",'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(document).ready(function(){initNavTree('group__group__bsp__wifi.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#define-members">Macros</a> &#124;
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle"><div class="title">WiFi Initialization</div></div>
</div><!--header-->
<div class="contents">
<a name="details" id="details"></a><h2 class="groupheader">General Description</h2>
<p >Macros to abstract out whether the LEDs &amp; Buttons are wired high or active low. </p>
<p >Basic integration code for interfacing the WiFi Host Driver (WHD) with the Board Support Packages (BSPs).</p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="define-members" name="define-members"></a>
Macros</h2></td></tr>
<tr class="memitem:ga42b37eb558b33e27c805a647d34e35ee"><td class="memItemLeft" align="right" valign="top"><a id="ga42b37eb558b33e27c805a647d34e35ee" name="ga42b37eb558b33e27c805a647d34e35ee"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><b>CY_WIFI_THREAD_STACK_SIZE</b>&#160;&#160;&#160;(5120)</td></tr>
<tr class="memdesc:ga42b37eb558b33e27c805a647d34e35ee"><td class="mdescLeft">&#160;</td><td class="mdescRight">Defines the amount of stack memory available for the wifi thread. <br /></td></tr>
<tr class="separator:ga42b37eb558b33e27c805a647d34e35ee"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga37de7fccd088d032385e7bea14d47af9"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#ga37de7fccd088d032385e7bea14d47af9">CY_WIFI_THREAD_PRIORITY</a>&#160;&#160;&#160;(CY_RTOS_PRIORITY_HIGH)</td></tr>
<tr class="memdesc:ga37de7fccd088d032385e7bea14d47af9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Defines the priority of the thread that services wifi packets.  <a href="group__group__bsp__wifi.html#ga37de7fccd088d032385e7bea14d47af9">More...</a><br /></td></tr>
<tr class="separator:ga37de7fccd088d032385e7bea14d47af9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga71f69d6ee495addd6dde24241a18bb08"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#ga71f69d6ee495addd6dde24241a18bb08">CY_WIFI_COUNTRY</a>&#160;&#160;&#160;(WHD_COUNTRY_AUSTRALIA)</td></tr>
<tr class="memdesc:ga71f69d6ee495addd6dde24241a18bb08"><td class="mdescLeft">&#160;</td><td class="mdescRight">Defines the country this will operate in for wifi initialization parameters.  <a href="group__group__bsp__wifi.html#ga71f69d6ee495addd6dde24241a18bb08">More...</a><br /></td></tr>
<tr class="separator:ga71f69d6ee495addd6dde24241a18bb08"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gacca3b2defde1e423420b6fb0c82a6bbb"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#gacca3b2defde1e423420b6fb0c82a6bbb">CY_WIFI_OOB_INTR_PRIORITY</a>&#160;&#160;&#160;(2)</td></tr>
<tr class="memdesc:gacca3b2defde1e423420b6fb0c82a6bbb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Defines the priority of the interrupt that handles out-of-band notifications from the wifi chip.  <a href="group__group__bsp__wifi.html#gacca3b2defde1e423420b6fb0c82a6bbb">More...</a><br /></td></tr>
<tr class="separator:gacca3b2defde1e423420b6fb0c82a6bbb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga0cc4b05c4d7f61925a0bf38761e456b9"><td class="memItemLeft" align="right" valign="top"><a id="ga0cc4b05c4d7f61925a0bf38761e456b9" name="ga0cc4b05c4d7f61925a0bf38761e456b9"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><b>CY_USE_OOB_INTR</b>&#160;&#160;&#160;(1u)</td></tr>
<tr class="memdesc:ga0cc4b05c4d7f61925a0bf38761e456b9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Defines whether to use the out-of-band pin to allow the WIFI chip to wake up the MCU. <br /></td></tr>
<tr class="separator:ga0cc4b05c4d7f61925a0bf38761e456b9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga6544e70afcc3d9eacca654701ff6b529"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#ga6544e70afcc3d9eacca654701ff6b529">CYBSP_WIFI_WL_REG_ON_GPIO_DRIVE_MODE</a>&#160;&#160;&#160;(CYHAL_GPIO_DRIVE_PULLUP)</td></tr>
<tr class="memdesc:ga6544e70afcc3d9eacca654701ff6b529"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default GPIO drive mode for CYBSP_WIFI_WL_REG_ON.  <a href="group__group__bsp__wifi.html#ga6544e70afcc3d9eacca654701ff6b529">More...</a><br /></td></tr>
<tr class="separator:ga6544e70afcc3d9eacca654701ff6b529"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga66442267682c4df7e7fb76929635675e"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#ga66442267682c4df7e7fb76929635675e">CYBSP_WIFI_WL_HOSTWAKE_DRIVE_MODE</a>&#160;&#160;&#160;(CYHAL_GPIO_DRIVE_NONE)</td></tr>
<tr class="memdesc:ga66442267682c4df7e7fb76929635675e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default GPIO drive mode for CYBSP_WIFI_WL_HOSTWAKE.  <a href="group__group__bsp__wifi.html#ga66442267682c4df7e7fb76929635675e">More...</a><br /></td></tr>
<tr class="separator:ga66442267682c4df7e7fb76929635675e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gabb1e6964c97c92841d6fb5b17600c60c"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#gabb1e6964c97c92841d6fb5b17600c60c">CYBSP_WIFI_WL_HOSTWAKE_INIT_STATE</a>&#160;&#160;&#160;(WHD_FALSE)</td></tr>
<tr class="memdesc:gabb1e6964c97c92841d6fb5b17600c60c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default GPIO drive mode for CYBSP_WIFI_WL_HOSTWAKE.  <a href="group__group__bsp__wifi.html#gabb1e6964c97c92841d6fb5b17600c60c">More...</a><br /></td></tr>
<tr class="separator:gabb1e6964c97c92841d6fb5b17600c60c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga1ddf3533adfa2e8f298f7edab7a8fa0c"><td class="memItemLeft" align="right" valign="top"><a id="ga1ddf3533adfa2e8f298f7edab7a8fa0c" name="ga1ddf3533adfa2e8f298f7edab7a8fa0c"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><b>CYBSP_RSLT_WIFI_INIT_FAILED</b>&#160;&#160;&#160;    (CY_RSLT_CREATE(CY_RSLT_TYPE_ERROR, CY_RSLT_MODULE_BOARD_LIB_WHD_INTEGRATION, 0))</td></tr>
<tr class="memdesc:ga1ddf3533adfa2e8f298f7edab7a8fa0c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initialization of the WiFi driver failed. <br /></td></tr>
<tr class="separator:ga1ddf3533adfa2e8f298f7edab7a8fa0c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gab868840379127847a984d02327620dd4"><td class="memItemLeft" align="right" valign="top"><a id="gab868840379127847a984d02327620dd4" name="gab868840379127847a984d02327620dd4"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><b>CYBSP_RSLT_WIFI_SDIO_ENUM_TIMEOUT</b>&#160;&#160;&#160;    (CY_RSLT_CREATE(CY_RSLT_TYPE_ERROR, CY_RSLT_MODULE_BOARD_LIB_WHD_INTEGRATION, 1))</td></tr>
<tr class="memdesc:gab868840379127847a984d02327620dd4"><td class="mdescLeft">&#160;</td><td class="mdescRight">SDIO enumeration failed. <br /></td></tr>
<tr class="separator:gab868840379127847a984d02327620dd4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga64a5bc537b95b4a38be7411be678de2a"><td class="memItemLeft" align="right" valign="top"><a id="ga64a5bc537b95b4a38be7411be678de2a" name="ga64a5bc537b95b4a38be7411be678de2a"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><b>CYBSP_RSLT_WIFI_SDIO_ENUM_IO_NOT_SUPPORTED</b>&#160;&#160;&#160;    (CY_RSLT_CREATE(CY_RSLT_TYPE_ERROR, CY_RSLT_MODULE_BOARD_LIB_WHD_INTEGRATION, 2))</td></tr>
<tr class="memdesc:ga64a5bc537b95b4a38be7411be678de2a"><td class="mdescLeft">&#160;</td><td class="mdescRight">SD device does not support IO functionality. <br /></td></tr>
<tr class="separator:ga64a5bc537b95b4a38be7411be678de2a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga63062663dcdabc7a753c54a27ce4f307"><td class="memItemLeft" align="right" valign="top"><a id="ga63062663dcdabc7a753c54a27ce4f307" name="ga63062663dcdabc7a753c54a27ce4f307"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><b>CYBSP_RSLT_WIFI_SDIO_ENUM_NOT_READY</b>&#160;&#160;&#160;    (CY_RSLT_CREATE(CY_RSLT_TYPE_ERROR, CY_RSLT_MODULE_BOARD_LIB_WHD_INTEGRATION, 3))</td></tr>
<tr class="memdesc:ga63062663dcdabc7a753c54a27ce4f307"><td class="mdescLeft">&#160;</td><td class="mdescRight">SDIO device is not ready. <br /></td></tr>
<tr class="separator:ga63062663dcdabc7a753c54a27ce4f307"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga854d0742defe0e9ee860209e7bd92512"><td class="memItemLeft" align="right" valign="top"><a id="ga854d0742defe0e9ee860209e7bd92512" name="ga854d0742defe0e9ee860209e7bd92512"></a>
#define&#160;</td><td class="memItemRight" valign="bottom"><b>CYBSP_RSLT_WIFI_SDIO_HS_SWITCH_FAILED</b>&#160;&#160;&#160;    (CY_RSLT_CREATE(CY_RSLT_TYPE_ERROR, CY_RSLT_MODULE_BOARD_LIB_WHD_INTEGRATION, 4))</td></tr>
<tr class="memdesc:ga854d0742defe0e9ee860209e7bd92512"><td class="mdescLeft">&#160;</td><td class="mdescRight">SDIO switch to High Speed mode failed. <br /></td></tr>
<tr class="separator:ga854d0742defe0e9ee860209e7bd92512"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="func-members" name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:ga1a1a868768f1624dc0e7132c2fcae988"><td class="memItemLeft" align="right" valign="top">cy_rslt_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#ga1a1a868768f1624dc0e7132c2fcae988">cybsp_wifi_init_primary_extended</a> (whd_interface_t *interface, whd_init_config_t *init_config, whd_resource_source_t *resource_if, whd_buffer_funcs_t *buffer_if, whd_netif_funcs_t *netif_if)</td></tr>
<tr class="memdesc:ga1a1a868768f1624dc0e7132c2fcae988"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes the primary interface for the WiFi driver on the board.  <a href="group__group__bsp__wifi.html#ga1a1a868768f1624dc0e7132c2fcae988">More...</a><br /></td></tr>
<tr class="separator:ga1a1a868768f1624dc0e7132c2fcae988"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:gafc78b1c0b031052308051088ee2021b7"><td class="memItemLeft" align="right" valign="top">static cy_rslt_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#gafc78b1c0b031052308051088ee2021b7">cybsp_wifi_init_primary</a> (whd_interface_t *interface)</td></tr>
<tr class="memdesc:gafc78b1c0b031052308051088ee2021b7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes the primary interface for the WiFi driver on the board using the default configuration, resource, buffer, and network interfaces.  <a href="group__group__bsp__wifi.html#gafc78b1c0b031052308051088ee2021b7">More...</a><br /></td></tr>
<tr class="separator:gafc78b1c0b031052308051088ee2021b7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga13b5648cec341b96068e2b372388eea4"><td class="memItemLeft" align="right" valign="top">cy_rslt_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#ga13b5648cec341b96068e2b372388eea4">cybsp_wifi_init_secondary</a> (whd_interface_t *interface, whd_mac_t *mac_address)</td></tr>
<tr class="memdesc:ga13b5648cec341b96068e2b372388eea4"><td class="mdescLeft">&#160;</td><td class="mdescRight">This function initializes and adds a secondary interface to the WiFi driver.  <a href="group__group__bsp__wifi.html#ga13b5648cec341b96068e2b372388eea4">More...</a><br /></td></tr>
<tr class="separator:ga13b5648cec341b96068e2b372388eea4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga77555750b014230bd78143aefb9f379b"><td class="memItemLeft" align="right" valign="top">cy_rslt_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#ga77555750b014230bd78143aefb9f379b">cybsp_wifi_deinit</a> (whd_interface_t interface)</td></tr>
<tr class="memdesc:ga77555750b014230bd78143aefb9f379b"><td class="mdescLeft">&#160;</td><td class="mdescRight">De-initializes all WiFi interfaces and the WiFi driver.  <a href="group__group__bsp__wifi.html#ga77555750b014230bd78143aefb9f379b">More...</a><br /></td></tr>
<tr class="separator:ga77555750b014230bd78143aefb9f379b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ga9f2fb2176d21e958727a75821b346e47"><td class="memItemLeft" align="right" valign="top">whd_driver_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__group__bsp__wifi.html#ga9f2fb2176d21e958727a75821b346e47">cybsp_get_wifi_driver</a> (void)</td></tr>
<tr class="memdesc:ga9f2fb2176d21e958727a75821b346e47"><td class="mdescLeft">&#160;</td><td class="mdescRight">Gets the wifi driver instance initialized by the driver.  <a href="group__group__bsp__wifi.html#ga9f2fb2176d21e958727a75821b346e47">More...</a><br /></td></tr>
<tr class="separator:ga9f2fb2176d21e958727a75821b346e47"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Macro Definition Documentation</h2>
<a id="ga37de7fccd088d032385e7bea14d47af9" name="ga37de7fccd088d032385e7bea14d47af9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga37de7fccd088d032385e7bea14d47af9">&#9670;&nbsp;</a></span>CY_WIFI_THREAD_PRIORITY</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define CY_WIFI_THREAD_PRIORITY&#160;&#160;&#160;(CY_RTOS_PRIORITY_HIGH)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Defines the priority of the thread that services wifi packets. </p>
<p >Legal values are defined by the RTOS being used. </p>

</div>
</div>
<a id="ga71f69d6ee495addd6dde24241a18bb08" name="ga71f69d6ee495addd6dde24241a18bb08"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga71f69d6ee495addd6dde24241a18bb08">&#9670;&nbsp;</a></span>CY_WIFI_COUNTRY</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define CY_WIFI_COUNTRY&#160;&#160;&#160;(WHD_COUNTRY_AUSTRALIA)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Defines the country this will operate in for wifi initialization parameters. </p>
<p >See the wifi-host-driver's whd_country_code_t for legal options. </p>

</div>
</div>
<a id="gacca3b2defde1e423420b6fb0c82a6bbb" name="gacca3b2defde1e423420b6fb0c82a6bbb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gacca3b2defde1e423420b6fb0c82a6bbb">&#9670;&nbsp;</a></span>CY_WIFI_OOB_INTR_PRIORITY</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define CY_WIFI_OOB_INTR_PRIORITY&#160;&#160;&#160;(2)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Defines the priority of the interrupt that handles out-of-band notifications from the wifi chip. </p>
<p >Legal values are defined by the MCU running this code. </p>

</div>
</div>
<a id="ga6544e70afcc3d9eacca654701ff6b529" name="ga6544e70afcc3d9eacca654701ff6b529"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga6544e70afcc3d9eacca654701ff6b529">&#9670;&nbsp;</a></span>CYBSP_WIFI_WL_REG_ON_GPIO_DRIVE_MODE</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define CYBSP_WIFI_WL_REG_ON_GPIO_DRIVE_MODE&#160;&#160;&#160;(CYHAL_GPIO_DRIVE_PULLUP)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Default GPIO drive mode for CYBSP_WIFI_WL_REG_ON. </p>
<p >Override with Makefile define <br  />
 </p>

</div>
</div>
<a id="ga66442267682c4df7e7fb76929635675e" name="ga66442267682c4df7e7fb76929635675e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga66442267682c4df7e7fb76929635675e">&#9670;&nbsp;</a></span>CYBSP_WIFI_WL_HOSTWAKE_DRIVE_MODE</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define CYBSP_WIFI_WL_HOSTWAKE_DRIVE_MODE&#160;&#160;&#160;(CYHAL_GPIO_DRIVE_NONE)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Default GPIO drive mode for CYBSP_WIFI_WL_HOSTWAKE. </p>
<p >Override with Makefile define <br  />
 </p>

</div>
</div>
<a id="gabb1e6964c97c92841d6fb5b17600c60c" name="gabb1e6964c97c92841d6fb5b17600c60c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gabb1e6964c97c92841d6fb5b17600c60c">&#9670;&nbsp;</a></span>CYBSP_WIFI_WL_HOSTWAKE_INIT_STATE</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">#define CYBSP_WIFI_WL_HOSTWAKE_INIT_STATE&#160;&#160;&#160;(WHD_FALSE)</td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Default GPIO drive mode for CYBSP_WIFI_WL_HOSTWAKE. </p>
<p >Override with Makefile define <br  />
 </p>

</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a id="ga1a1a868768f1624dc0e7132c2fcae988" name="ga1a1a868768f1624dc0e7132c2fcae988"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga1a1a868768f1624dc0e7132c2fcae988">&#9670;&nbsp;</a></span>cybsp_wifi_init_primary_extended()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cy_rslt_t cybsp_wifi_init_primary_extended </td>
          <td>(</td>
          <td class="paramtype">whd_interface_t *&#160;</td>
          <td class="paramname"><em>interface</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">whd_init_config_t *&#160;</td>
          <td class="paramname"><em>init_config</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">whd_resource_source_t *&#160;</td>
          <td class="paramname"><em>resource_if</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">whd_buffer_funcs_t *&#160;</td>
          <td class="paramname"><em>buffer_if</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">whd_netif_funcs_t *&#160;</td>
          <td class="paramname"><em>netif_if</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Initializes the primary interface for the WiFi driver on the board. </p>
<p >This sets up the WHD interface to use the <a class="el" href="group__group__bsp__network__buffer.html">Buffer management</a> APIs and to communicate over the SDIO interface on the board. This function does the following:<br  />
 1) Initializes the WiFi driver.<br  />
 2) Turns on the WiFi chip.</p>
<dl class="section note"><dt>Note</dt><dd>This function cannot be called multiple times. If the interface needs to be reinitialized, <a class="el" href="group__group__bsp__wifi.html#ga77555750b014230bd78143aefb9f379b">cybsp_wifi_deinit</a> must be called before calling this function again.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[out]</td><td class="paramname">interface</td><td>Interface to be initialized </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">init_config</td><td>Pointer to the configuration parameters to initialize the driver. Passing NULL will use default values. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">resource_if</td><td>Pointer to resource interface to provide resources to the driver initialization process. Passing NULL will use the default. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">buffer_if</td><td>Pointer to a buffer interface to provide buffer related services to the driver instance. Passing NULL will use the default. </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">netif_if</td><td>Pointer to a whd_netif_funcs_t to provide network stack services to the driver instance. Passing NULL will use the default.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>CY_RSLT_SUCCESS for successful initialization or error if initialization failed. </dd></dl>

</div>
</div>
<a id="gafc78b1c0b031052308051088ee2021b7" name="gafc78b1c0b031052308051088ee2021b7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#gafc78b1c0b031052308051088ee2021b7">&#9670;&nbsp;</a></span>cybsp_wifi_init_primary()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static cy_rslt_t cybsp_wifi_init_primary </td>
          <td>(</td>
          <td class="paramtype">whd_interface_t *&#160;</td>
          <td class="paramname"><em>interface</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Initializes the primary interface for the WiFi driver on the board using the default configuration, resource, buffer, and network interfaces. </p>
<p >See <a class="el" href="group__group__bsp__wifi.html#ga1a1a868768f1624dc0e7132c2fcae988" title="Initializes the primary interface for the WiFi driver on the board.">cybsp_wifi_init_primary_extended()</a> for more details.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[out]</td><td class="paramname">interface</td><td>Interface to be initialized</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>CY_RSLT_SUCCESS for successful initialization or error if initialization failed. </dd></dl>

</div>
</div>
<a id="ga13b5648cec341b96068e2b372388eea4" name="ga13b5648cec341b96068e2b372388eea4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga13b5648cec341b96068e2b372388eea4">&#9670;&nbsp;</a></span>cybsp_wifi_init_secondary()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cy_rslt_t cybsp_wifi_init_secondary </td>
          <td>(</td>
          <td class="paramtype">whd_interface_t *&#160;</td>
          <td class="paramname"><em>interface</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">whd_mac_t *&#160;</td>
          <td class="paramname"><em>mac_address</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>This function initializes and adds a secondary interface to the WiFi driver. </p>
<dl class="section note"><dt>Note</dt><dd>This function does not initialize the WiFi driver or turn on the WiFi chip. That is required to be done by first calling <a class="el" href="group__group__bsp__wifi.html#gafc78b1c0b031052308051088ee2021b7">cybsp_wifi_init_primary</a>.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[out]</td><td class="paramname">interface</td><td>Interface to be initialized </td></tr>
    <tr><td class="paramdir">[in]</td><td class="paramname">mac_address</td><td>Mac address for secondary interface</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>CY_RSLT_SUCCESS for successful initialization or error if initialization failed. </dd></dl>

</div>
</div>
<a id="ga77555750b014230bd78143aefb9f379b" name="ga77555750b014230bd78143aefb9f379b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga77555750b014230bd78143aefb9f379b">&#9670;&nbsp;</a></span>cybsp_wifi_deinit()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">cy_rslt_t cybsp_wifi_deinit </td>
          <td>(</td>
          <td class="paramtype">whd_interface_t&#160;</td>
          <td class="paramname"><em>interface</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>De-initializes all WiFi interfaces and the WiFi driver. </p>
<p >This function does the following:<br  />
 1) Deinitializes all WiFi interfaces.<br  />
 2) Deinitializes the WiFi driver.<br  />
 3) Turns off the WiFi chip.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">interface</td><td>Either the Primary or Secondary interface.</td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>CY_RSLT_SUCCESS for successful de-initialization or error if de-initialization failed. </dd></dl>

</div>
</div>
<a id="ga9f2fb2176d21e958727a75821b346e47" name="ga9f2fb2176d21e958727a75821b346e47"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ga9f2fb2176d21e958727a75821b346e47">&#9670;&nbsp;</a></span>cybsp_get_wifi_driver()</h2>

<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">whd_driver_t cybsp_get_wifi_driver </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Gets the wifi driver instance initialized by the driver. </p>
<p >This should only be called after being initialized by <a class="el" href="group__group__bsp__wifi.html#gafc78b1c0b031052308051088ee2021b7">cybsp_wifi_init_primary()</a> and before being deinitialized by <a class="el" href="group__group__bsp__wifi.html#ga77555750b014230bd78143aefb9f379b">cybsp_wifi_deinit()</a>. This is also the only time where the driver reference is valid.</p>
<dl class="section return"><dt>Returns</dt><dd>Wifi driver instance pointer. </dd></dl>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part
<div id="nav-path" class="navpath">
    <ul>
        <li class="footer">
            Generated for <b>WiFi Host Driver Board Support Package Integration (whd-bsp-integration)</b> by <b>Cypress Semiconductor Corporation</b>.
            All rights reserved.
        </li>
    </ul>
</div>
-->
</body>
</html>
